package com.neuedu.controller;

import com.neuedu.entity.InterviewRecord;
import com.neuedu.service.InterviewRecordService;
import com.neuedu.vo.ResultJson;
import jakarta.annotation.Resource;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * <p>
 * 模拟面试 前端控制器
 * </p>
 *
 * @author wangyu
 * @since 2025-09-12
 */
@RestController
@RequestMapping("/interviewRecord")
public class InterviewRecordController {
    @Resource
    InterviewRecordService interviewRecordService;
    @GetMapping("/list")
    ResultJson<List<InterviewRecord>> list(Long login_id) {
        return ResultJson.success(interviewRecordService.getRecordList(login_id));
    }
    @GetMapping("/getByUserId")
    ResultJson<List<InterviewRecord>> getByUserId(Long userId) {
        return ResultJson.success(interviewRecordService.getRecordList(userId));
    }
}
